#ifndef WORLD_H
#define WORLD_H

#include "GameObject.h"
#include "GameObjectFactory.h"
#include <list>
#include "Board.h"

class World
{
public:
	World(GameObjectFactory* factory);
	virtual ~World();

	void Resize(unsigned int width, unsigned int height);
	GameObject* AddRobot(const std::string& type, unsigned int cellX, unsigned int cellY);


	void Move(GameObject* object, unsigned int cellX, unsigned int cellY);

	void Print();
protected:
private:
	void AddObject(GameObject* object, unsigned int cellX, unsigned int cellY);
	void Clear();

	std::list<GameObject*> objects;
	Board board;


	GameObjectFactory *objectFactory;
};

#endif //WORLD_H
